import java.util.Calendar;
import java.util.Date;

public enum Welcome {
    MORNING("Good Moring!早上好啊！"),
    NOON("Good noon!中午好啊！"),
    AFTERNOON("Good Afternoon!下午好啊！"),
    NIGHT("Good Night!晚上好啊！"),
    DAWN("Good dawn!凌晨好啊！");
    private String string;

    public String getString() {
        return string;
    }

    public void setString(String string) {
        this.string = string;
    }
    Welcome(String string){
        this.string = string;
    }

}
class Test{
    public static void main(String[] args) {
        Date date = new Date();
        int hour = date.getHours();
        if (hour > 6 && hour <=11){
            System.out.println(Welcome.MORNING.getString());
        }else if (hour > 11 && hour <= 14){
            System.out.println(Welcome.NOON.getString());
        }else if (hour > 14&& hour <=18){
            System.out.println(Welcome.NIGHT.getString());
        }else if (hour > 18 && hour <= 23){
            System.out.println(Welcome.NIGHT.getString());
        }else {
            System.out.println(Welcome.DAWN.getString());
        }
    }
}
